The outline of moving picture coding/decoding will be described below. Moving picture coding is generally performed in a coding apparatus shown in FIG. 13. One frame of a moving picture to be coded is composed of one luminance signal (Y signal: 61) and two color difference signals (Cr signal: 62, Cb signal: 63) as shown in FIG. 3, and the picture size of the color difference signal is equivalent to ½ of the luminance signal in both length and width. In a general video standard, each frame of a moving picture is divided into small blocks and is reconstructed in units of block called a macroblock.
The above-mentioned macroblock is composed of one Y signal block 30 including 16.times.16 pixels, a Cr signal block 31 and a Cb signal block 32 respectively including 8.times.8 pixels and respectively spatially coincident with one Y signal block as shown in FIG. 5. A picture signal is coded in units of macroblock. Coding is roughly classified into intracoding (an intramode) and predictive coding (an intermode).
In the coding apparatus shown in FIG. 13, in the case of intracoding, an input macroblock picture 201 to be coded is divided into DCT coding blocks, DCT is directly applied to a DCT coding block in a DCT device 203, and the value is transformed to a DCT coefficients. Each transformed coefficient is quantized in a quantizer 204 and is coded in a multiplexer 206.
DCT coding block size is generally (8.times.8) pixels in a conventional type coding method, however, recently DCT in 4.times.4-pixel size is also examined in MPEG-4 Part 10 (Advanced Video Coding) and others.
As shown in FIG. 6, each macroblock is divided into 24 pieces of 4.times.4-pixel blocks and each 4.times.4-pixel block is transformed to 16 DCT coefficients in DCT device 203.
A part of the quantized DCT coefficients is decoded to the input macroblock in an inverse quantizer 207 and an inverse DCT device 208 respectively in a local decoder 220 and is synthesized in a frame memory 210. The local decoder 220 generates the same decoded picture to that generated by a decoder described later. A picture stored in the frame memory 210 is used for the prediction of a temporal direction described later. The intracoding is applied to a macroblock (also including a first coding frame) having no similar part in the preceding frame and a part in which the accumulation of operation mismatch in DCT is to be solved.
In the case of interceding (predictive coding), processing for motion compensation between the input macroblock picture 201 and a decoded picture (a reference frame) of the coded frame stored in the frame memory 210 is executed in a motion compensator 211. The motion compensation means compression technique in a temporal direction for searching and deriving the similar part (generally, a part smaller in the sum of the absolute values of predictive error signals in a block or the square error sum is selected) to the contents of a target macroblock from a reference frame and coding the amount of its motion (a motion vector).
FIG. 4 shows processing for motion compensation. FIG. 4 shows a prediction block 75 and a motion vector 76 on the previous frame 73 (a reference frame) of a luminance signal block 72 of the current frame 71 enclosed by a thick framework. The motion vector 76 shows the amount of displacement from a block 74 shown by a broken line on the previous frame located in the spatially same position as the block enclosed by the thick framework of the current frame to the prediction block 75 on the previous frame (the length of a motion vector for a color difference signal is equivalent to a half of that of a luminance signal and is not coded). The detected motion vector is coded in the multiplexer 206 after differential processing between it and a predictive motion vector (predicted based upon a motion vector of the adjacent block) generated by an MV predictor 215. Differential processing is performed between a predictive macroblock picture 213 extracted from the previous frame by motion compensation and the input macroblock picture 201 of the current frame in a differentiator 202 and a differential macroblock picture is generated.
The differential macroblock picture is divided into 24 pieces of 4.times.4-pixel blocks as shown in FIG. 6 and each 4.times.4-pixel block is transformed to 16 DCT coefficients in the DCT device 203. Each DCT coefficient is quantized in the quantizer 204 and is coded in the multiplexer 206. In the case of interceding, after these quantized DCT coefficient are decoded to a differential macroblock picture in the inverse quantizer 207 and the inverse DCT device 208 respectively in the local decoder 220 and is added to a predictive macroblock picture in an adder 209, it is also synthesized in the frame memory 210. In this case, the number of motion vectors to be coded in one macroblock is one, however, a method of dividing a macroblock into further small blocks, calculating and coding a motion vector every small block is general. For example, MPEG-4 Part 10 (Advanced Video Coding) considers a macroblock division type (a luminance component) for motion compensation as shown in FIG. 7. Four types of types 51 to 54 are basic. As for the type 54, five types of types 54a, 54b, 54c, 54d and intracoding are further selected for four pieces of 8.times.8 blocks 54-0 to 54-3.
Further, a method of the motion compensation of predictive coding is classified into forward predictive coding in which motion compensation is performed using the information of a temporarily past frame and bi-directional predictive coding in which motion compensation is performed using temporarily past and future frames. In motion compensation in the forward predictive coding, only forward prediction is dealt, however, in motion compensation in the bi-directional coding, in addition to forward prediction, backward prediction, bi-directional prediction and direct prediction in which bi-directional prediction is performed utilizing motion vector information in a temporarily future frame are dealt.
As for the coding accuracy of a motion vector, the accuracy of an integer pixel or a smaller pixel is generally dealt. For example, in Advanced Simple Profile of MPEG-4 Part 2′, ½-pixel accuracy and ¼-pixel accuracy can be selected for each bitstream. The description of a method of calculating a predicted value of the accuracy of an integer pixel or a smaller pixel is omitted, however, in the case of ½-pixel accuracy, a 2-tap linear filter is suitably used according to the position of a pixel and in the case of ¼-pixel accuracy, an 8-tap filter and a 2-tap filter are suitably used according to the position of a pixel. In MPEG-4 Part 10, it is also examined to represent a motion vector at ¼-pixel accuracy and a predicted value is calculated using a 6-tap filter and the 2-tap filter. As described above, predictive performance is enhanced by using the multiple number of taps.
A frame in which intracoding is applied to all macroblocks is called I-Picture, a frame by forward predictive coding or intracoding is called P-Picture, and a frame by bi-directional coding or intracoding is called B-Picture. In P-Picture or B-Picture, it is selected in an INTRA/INTER decision device 214 shown in FIG. 13 which of predictive coding or intracoding is used for each macroblock and the result of the decision 218 is coded in the multiplexer 206.
A coded signal of a moving picture is decoded according to a reverse procedure to coding. Generally, decoding is performed in a moving picture decoding apparatus shown in FIG. 14.
In a code decoder 501, input coded data is analyzed, information related to a motion vector and macroblock type information are outputed to an MV predictor 508 and quantized DCT coefficient information is outputed to an inverse quantizer 502. In case a macroblock type is intracoding, inverse quantization and inverse DCT are applied to decoded quantized DCT coefficient information every 4.times.4-pixel block in the inverse quantizer 502 and the inverse DCT device 503, and a macroblock picture is reconstructed. In case a predictive mode of a macroblock is predictive coding, a decoded motion vector is calculated based upon a decoded differential motion vector and a predictive motion vector in the MV predictor 508 and is input to a motion compensator 504. In the motion compensator 504, a predictive macroblock picture is extracted from a frame memory 507 in which the decoded picture of the previous frame is stored according to the amount of motion.
Next, inverse quantization and inverse DCT are applied to coded data related to a predictive error signal every 4.times.4-pixel block in the inverse quantizer 502 and the inverse DCT device 503, and a differential macroblock picture is reconstructed. The predictive macroblock picture and the differential macroblock picture are added in an adder 505 and a macroblock picture is reconstructed. The reconstructed macroblock picture is synthesized with a decoded frame picture in a synthesizer 506. The decoded frame picture is stored in a frame memory 507 for the prediction of the next frame.
For a document related to the invention, there is Japanese published unexamined patent application No. Heill-46364. In this document, in moving picture coding/decoding methods for executing coding/decoding processing in units of block, some types of motion vector precisions are prepared and means for switching motion vector coding accuracy in units of plural pieces of bundled blocks is disclosed.
In the motion compensation coding of a moving picture signal heretofore known, plural types of motion vectors included in a block are prepared and a coding method in which the coding accuracy of a motion vector is high as in the case of ⅛-pixel accuracy is studied. However, there is a tendency that a method of coding with the small number of motion vectors is selected because of the quantity of codes of motion vectors even if plural motions are included in a block. Besides, in case a predictive pixel is generated at the accuracy of an integer pixel or a smaller pixel using a multiple-tap filter, a problem of memory access that the number of pixels in a reference picture used to generate one predictive block is increased occurs. This problem comes into question particularly when motion compensation is performed.
Therefore, the object of the invention is to provide a coding method of a moving picture signal, a decoding method, a coding apparatus and a decoding apparatus in which the quantity of codes of motion vectors can be reduced and motion predictive error information by the increase of the number of blocks in a block to be coded can be reduced.
Another object of the invention is to reduce a range of memory access in motion compensation in the coding apparatus and the decoding apparatus.